The present invention relates to a data processing system having a re-entrant function for subroutines.
Many current microprocessors adopt the stack pointer system for the linkage of an interrupt and a subroutine. Although the system is capable of many applications, it requires save/restore operations for data in the registers in the interrupt service programs or the like. This causes unavoidable overhead in processing by the central processing unit (hereinafter referred to as CPU).
A prior art technique is disclosed in U.S. Pat. No. 4,217,638 according to which a switching system comprising a plurality of register sets is constructed of general registers. The inventor herein is a coinventor in the aforementioned U.S. Patent which is assigned to the assignee of this application. The present invention provides an improvement over the aforementioned U.S. Patent.